<!DOCTYPE html>
<html>
<head>
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  <!--The viewport meta tag is used to improve the presentation and behavior of the samples on iOS devices-->
  <meta name="viewport" content="initial-scale=1, maximum-scale=1,user-scalable=no">
  <title>Simple Image Service</title>
  <link rel="stylesheet" href="http://js.arcgis.com/3.9/js/esri/css/esri.css" />

  <style>
    html, body, #map {
      height: 100%;
      width: 100%;
      margin: 0;
      padding: 0;
    }
  </style>
</head>
<body>
  <div id="map"> </div>


  <script type="text/javascript">
    var dojoConfig = {
      parseOnLoad:true,
      isDebug: true,
      packages: [
          {
            name: "esri",
            location: "../../../js/esri"
          }
      ]
    };
  </script>
  <script type="text/javascript" src="../../../dojo/dojo/dojo.js"></script>

  <script>
    var map;
    require([
      "esri/map",
      "esri/layers/ArcGISImageServiceLayer",
      "esri/layers/ImageServiceParameters",
      "esri/layers/MosaicRule",
      "esri/layers/DimensionalDefinition",
      "dojo/parser",
      "dojo/domReady!"
    ], function (Map, ArcGISImageServiceLayer, ImageServiceParameters, MosaicRule, DimensionalDefinition, parser) {
      parser.parse();
      map = new Map("map", {
        basemap: "topo",
        center: [-79.40, 43.64],
        zoom: 12
      });

      var params = new ImageServiceParameters();
      params.noData = 0;
      params.mosaicRule = new MosaicRule();
      params.mosaicRule.multidimensionalDefinition = [];
      params.mosaicRule.multidimensionalDefinition.push(new DimensionalDefinition({
        variableName: "uwnd",
        dimensionName: "StdTime",
        values: [1188604800000]
      }));

      var imageServiceLayer = new ArcGISImageServiceLayer("http://dev01055:6080/arcgis/rest/services/WindUV/ImageServer", {
        imageServiceParameters: params,
        opacity: 0.75
      });
      map.addLayer(imageServiceLayer);
    });
  </script>
</body>

</html>
